Optimal. Leaf size=74 \[ \frac {a \sec ^4(c+d x)}{4 d}-\frac {b \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {b \tan (c+d x) \sec ^3(c+d x)}{4 d}-\frac {b \tan (c+d x) \sec (c+d x)}{8 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.11, antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.240, Rules used = {2834, 2606, 30, 2611, 3768, 3770} \[ \frac {a \sec ^4(c+d x)}{4 d}-\frac {b \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {b \tan (c+d x) \sec ^3(c+d x)}{4 d}-\frac {b \tan (c+d x) \sec (c+d x)}{8 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 30
Rule 2606
Rule 2611
Rule 2834
Rule 3768
Rule 3770
Rubi steps
\begin {align*} \int \sec ^4(c+d x) (a+b \sin (c+d x)) \tan (c+d x) \, dx &=a \int \sec ^4(c+d x) \tan (c+d x) \, dx+b \int \sec ^3(c+d x) \tan ^2(c+d x) \, dx\\ &=\frac {b \sec ^3(c+d x) \tan (c+d x)}{4 d}-\frac {1}{4} b \int \sec ^3(c+d x) \, dx+\frac {a \operatorname {Subst}\left (\int x^3 \, dx,x,\sec (c+d x)\right )}{d}\\ &=\frac {a \sec ^4(c+d x)}{4 d}-\frac {b \sec (c+d x) \tan (c+d x)}{8 d}+\frac {b \sec ^3(c+d x) \tan (c+d x)}{4 d}-\frac {1}{8} b \int \sec (c+d x) \, dx\\ &=-\frac {b \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {a \sec ^4(c+d x)}{4 d}-\frac {b \sec (c+d x) \tan (c+d x)}{8 d}+\frac {b \sec ^3(c+d x) \tan (c+d x)}{4 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.02, size = 74, normalized size = 1.00 \[ \frac {a \sec ^4(c+d x)}{4 d}-\frac {b \tanh ^{-1}(\sin (c+d x))}{8 d}+\frac {b \tan (c+d x) \sec ^3(c+d x)}{4 d}-\frac {b \tan (c+d x) \sec (c+d x)}{8 d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.42, size = 80, normalized size = 1.08 \[ -\frac {b \cos \left (d x + c\right )^{4} \log \left (\sin \left (d x + c\right ) + 1\right ) - b \cos \left (d x + c\right )^{4} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (b \cos \left (d x + c\right )^{2} - 2 \, b\right )} \sin \left (d x + c\right ) - 4 \, a}{16 \, d \cos \left (d x + c\right )^{4}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.23, size = 67, normalized size = 0.91 \[ -\frac {b \log \left ({\left | \sin \left (d x + c\right ) + 1 \right |}\right ) - b \log \left ({\left | \sin \left (d x + c\right ) - 1 \right |}\right ) - \frac {2 \, {\left (b \sin \left (d x + c\right )^{3} + b \sin \left (d x + c\right ) + 2 \, a\right )}}{{\left (\sin \left (d x + c\right )^{2} - 1\right )}^{2}}}{16 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.20, size = 92, normalized size = 1.24 \[ \frac {a}{4 d \cos \left (d x +c \right )^{4}}+\frac {b \left (\sin ^{3}\left (d x +c \right )\right )}{4 d \cos \left (d x +c \right )^{4}}+\frac {b \left (\sin ^{3}\left (d x +c \right )\right )}{8 d \cos \left (d x +c \right )^{2}}+\frac {b \sin \left (d x +c \right )}{8 d}-\frac {b \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{8 d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.34, size = 75, normalized size = 1.01 \[ -\frac {b \log \left (\sin \left (d x + c\right ) + 1\right ) - b \log \left (\sin \left (d x + c\right ) - 1\right ) - \frac {2 \, {\left (b \sin \left (d x + c\right )^{3} + b \sin \left (d x + c\right ) + 2 \, a\right )}}{\sin \left (d x + c\right )^{4} - 2 \, \sin \left (d x + c\right )^{2} + 1}}{16 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 18.54, size = 158, normalized size = 2.14 \[ \frac {\frac {b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{4}+2\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6+\frac {7\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{4}+\frac {7\,b\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{4}+2\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+\frac {b\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{4}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8-4\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6+6\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4-4\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )}-\frac {b\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{4\,d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________